3.848 \(\int \frac{\tan ^4(c+d x)}{(a+a \sin (c+d x))^4} \, dx\)

Optimal. Leaf size=145 \[ \frac{8 \tan ^{11}(c+d x)}{11 a^4 d}+\frac{16 \tan ^9(c+d x)}{9 a^4 d}+\frac{9 \tan ^7(c+d x)}{7 a^4 d}+\frac{\tan ^5(c+d x)}{5 a^4 d}-\frac{8 \sec ^{11}(c+d x)}{11 a^4 d}+\frac{20 \sec ^9(c+d x)}{9 a^4 d}-\frac{16 \sec ^7(c+d x)}{7 a^4 d}+\frac{4 \sec ^5(c+d x)}{5 a^4 d} \]

[Out]

(4*Sec[c + d*x]^5)/(5*a^4*d) - (16*Sec[c + d*x]^7)/(7*a^4*d) + (20*Sec[c + d*x]^9)/(9*a^4*d) - (8*Sec[c + d*x]
^11)/(11*a^4*d) + Tan[c + d*x]^5/(5*a^4*d) + (9*Tan[c + d*x]^7)/(7*a^4*d) + (16*Tan[c + d*x]^9)/(9*a^4*d) + (8
*Tan[c + d*x]^11)/(11*a^4*d)

________________________________________________________________________________________

Rubi [A]  time = 0.31329, antiderivative size = 145, normalized size of antiderivative = 1., number of steps used = 17, number of rules used = 5, integrand size = 21, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.238, Rules used = {2711, 2607, 270, 2606, 14} \[ \frac{8 \tan ^{11}(c+d x)}{11 a^4 d}+\frac{16 \tan ^9(c+d x)}{9 a^4 d}+\frac{9 \tan ^7(c+d x)}{7 a^4 d}+\frac{\tan ^5(c+d x)}{5 a^4 d}-\frac{8 \sec ^{11}(c+d x)}{11 a^4 d}+\frac{20 \sec ^9(c+d x)}{9 a^4 d}-\frac{16 \sec ^7(c+d x)}{7 a^4 d}+\frac{4 \sec ^5(c+d x)}{5 a^4 d} \]

Antiderivative was successfully verified.

[In]

Int[Tan[c + d*x]^4/(a + a*Sin[c + d*x])^4,x]

[Out]

(4*Sec[c + d*x]^5)/(5*a^4*d) - (16*Sec[c + d*x]^7)/(7*a^4*d) + (20*Sec[c + d*x]^9)/(9*a^4*d) - (8*Sec[c + d*x]
^11)/(11*a^4*d) + Tan[c + d*x]^5/(5*a^4*d) + (9*Tan[c + d*x]^7)/(7*a^4*d) + (16*Tan[c + d*x]^9)/(9*a^4*d) + (8
*Tan[c + d*x]^11)/(11*a^4*d)

Rule 2711

Int[((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((g_.)*tan[(e_.) + (f_.)*(x_)])^(p_.), x_Symbol] :> Dist[a^(2*
m), Int[ExpandIntegrand[(g*Tan[e + f*x])^p/Sec[e + f*x]^m, (a*Sec[e + f*x] - b*Tan[e + f*x])^(-m), x], x], x]
/; FreeQ[{a, b, e, f, g, p}, x] && EqQ[a^2 - b^2, 0] && ILtQ[m, 0]

Rule 2607

Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[1/f, Subst[Int[(b*x)
^n*(1 + x^2)^(m/2 - 1), x], x, Tan[e + f*x]], x] /; FreeQ[{b, e, f, n}, x] && IntegerQ[m/2] &&  !(IntegerQ[(n
- 1)/2] && LtQ[0, n, m - 1])

Rule 270

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*(a + b*x^n)^p,
 x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0]

Rule 2606

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rubi steps

\begin{align*} \int \frac{\tan ^4(c+d x)}{(a+a \sin (c+d x))^4} \, dx &=\frac{\int \left (a^4 \sec ^8(c+d x) \tan ^4(c+d x)-4 a^4 \sec ^7(c+d x) \tan ^5(c+d x)+6 a^4 \sec ^6(c+d x) \tan ^6(c+d x)-4 a^4 \sec ^5(c+d x) \tan ^7(c+d x)+a^4 \sec ^4(c+d x) \tan ^8(c+d x)\right ) \, dx}{a^8}\\ &=\frac{\int \sec ^8(c+d x) \tan ^4(c+d x) \, dx}{a^4}+\frac{\int \sec ^4(c+d x) \tan ^8(c+d x) \, dx}{a^4}-\frac{4 \int \sec ^7(c+d x) \tan ^5(c+d x) \, dx}{a^4}-\frac{4 \int \sec ^5(c+d x) \tan ^7(c+d x) \, dx}{a^4}+\frac{6 \int \sec ^6(c+d x) \tan ^6(c+d x) \, dx}{a^4}\\ &=\frac{\operatorname{Subst}\left (\int x^8 \left (1+x^2\right ) \, dx,x,\tan (c+d x)\right )}{a^4 d}+\frac{\operatorname{Subst}\left (\int x^4 \left (1+x^2\right )^3 \, dx,x,\tan (c+d x)\right )}{a^4 d}-\frac{4 \operatorname{Subst}\left (\int x^6 \left (-1+x^2\right )^2 \, dx,x,\sec (c+d x)\right )}{a^4 d}-\frac{4 \operatorname{Subst}\left (\int x^4 \left (-1+x^2\right )^3 \, dx,x,\sec (c+d x)\right )}{a^4 d}+\frac{6 \operatorname{Subst}\left (\int x^6 \left (1+x^2\right )^2 \, dx,x,\tan (c+d x)\right )}{a^4 d}\\ &=\frac{\operatorname{Subst}\left (\int \left (x^8+x^{10}\right ) \, dx,x,\tan (c+d x)\right )}{a^4 d}+\frac{\operatorname{Subst}\left (\int \left (x^4+3 x^6+3 x^8+x^{10}\right ) \, dx,x,\tan (c+d x)\right )}{a^4 d}-\frac{4 \operatorname{Subst}\left (\int \left (-x^4+3 x^6-3 x^8+x^{10}\right ) \, dx,x,\sec (c+d x)\right )}{a^4 d}-\frac{4 \operatorname{Subst}\left (\int \left (x^6-2 x^8+x^{10}\right ) \, dx,x,\sec (c+d x)\right )}{a^4 d}+\frac{6 \operatorname{Subst}\left (\int \left (x^6+2 x^8+x^{10}\right ) \, dx,x,\tan (c+d x)\right )}{a^4 d}\\ &=\frac{4 \sec ^5(c+d x)}{5 a^4 d}-\frac{16 \sec ^7(c+d x)}{7 a^4 d}+\frac{20 \sec ^9(c+d x)}{9 a^4 d}-\frac{8 \sec ^{11}(c+d x)}{11 a^4 d}+\frac{\tan ^5(c+d x)}{5 a^4 d}+\frac{9 \tan ^7(c+d x)}{7 a^4 d}+\frac{16 \tan ^9(c+d x)}{9 a^4 d}+\frac{8 \tan ^{11}(c+d x)}{11 a^4 d}\\ \end{align*}

Mathematica [A]  time = 0.461469, size = 166, normalized size = 1.14 \[ \frac{\sec ^3(c+d x) (501600 \sin (c+d x)-70136 \sin (2 (c+d x))-200288 \sin (3 (c+d x))-25504 \sin (4 (c+d x))+48800 \sin (5 (c+d x))+6376 \sin (6 (c+d x))-1952 \sin (7 (c+d x))-78903 \cos (c+d x)-183040 \cos (2 (c+d x))+8767 \cos (3 (c+d x))+62464 \cos (4 (c+d x))+19925 \cos (5 (c+d x))-15616 \cos (6 (c+d x))-797 \cos (7 (c+d x))+168960)}{3548160 a^4 d (\sin (c+d x)+1)^4} \]

Antiderivative was successfully verified.

[In]

Integrate[Tan[c + d*x]^4/(a + a*Sin[c + d*x])^4,x]

[Out]

(Sec[c + d*x]^3*(168960 - 78903*Cos[c + d*x] - 183040*Cos[2*(c + d*x)] + 8767*Cos[3*(c + d*x)] + 62464*Cos[4*(
c + d*x)] + 19925*Cos[5*(c + d*x)] - 15616*Cos[6*(c + d*x)] - 797*Cos[7*(c + d*x)] + 501600*Sin[c + d*x] - 701
36*Sin[2*(c + d*x)] - 200288*Sin[3*(c + d*x)] - 25504*Sin[4*(c + d*x)] + 48800*Sin[5*(c + d*x)] + 6376*Sin[6*(
c + d*x)] - 1952*Sin[7*(c + d*x)]))/(3548160*a^4*d*(1 + Sin[c + d*x])^4)

________________________________________________________________________________________

Maple [A]  time = 0.135, size = 190, normalized size = 1.3 \begin{align*} 32\,{\frac{1}{d{a}^{4}} \left ( -{\frac{1}{1536\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) -1 \right ) ^{3}}}-{\frac{1}{1024\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) -1 \right ) ^{2}}}-1/22\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{-11}+1/4\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{-10}-{\frac{11}{18\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{9}}}+{\frac{7}{8\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{8}}}-{\frac{179}{224\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{7}}}+{\frac{89}{192\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{6}}}-{\frac{49}{320\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{5}}}+{\frac{1}{64\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{4}}}+{\frac{7}{1536\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{3}}}+{\frac{1}{1024\, \left ( \tan \left ( 1/2\,dx+c/2 \right ) +1 \right ) ^{2}}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sec(d*x+c)^4*sin(d*x+c)^4/(a+a*sin(d*x+c))^4,x)

[Out]

32/d/a^4*(-1/1536/(tan(1/2*d*x+1/2*c)-1)^3-1/1024/(tan(1/2*d*x+1/2*c)-1)^2-1/22/(tan(1/2*d*x+1/2*c)+1)^11+1/4/
(tan(1/2*d*x+1/2*c)+1)^10-11/18/(tan(1/2*d*x+1/2*c)+1)^9+7/8/(tan(1/2*d*x+1/2*c)+1)^8-179/224/(tan(1/2*d*x+1/2
*c)+1)^7+89/192/(tan(1/2*d*x+1/2*c)+1)^6-49/320/(tan(1/2*d*x+1/2*c)+1)^5+1/64/(tan(1/2*d*x+1/2*c)+1)^4+7/1536/
(tan(1/2*d*x+1/2*c)+1)^3+1/1024/(tan(1/2*d*x+1/2*c)+1)^2)

________________________________________________________________________________________

Maxima [B]  time = 1.21688, size = 659, normalized size = 4.54 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^4*sin(d*x+c)^4/(a+a*sin(d*x+c))^4,x, algorithm="maxima")

[Out]

32/3465*(16*sin(d*x + c)/(cos(d*x + c) + 1) + 50*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 + 64*sin(d*x + c)^3/(cos(
d*x + c) + 1)^3 - 22*sin(d*x + c)^4/(cos(d*x + c) + 1)^4 + 517*sin(d*x + c)^5/(cos(d*x + c) + 1)^5 + 726*sin(d
*x + c)^6/(cos(d*x + c) + 1)^6 + 1650*sin(d*x + c)^7/(cos(d*x + c) + 1)^7 + 924*sin(d*x + c)^8/(cos(d*x + c) +
 1)^8 + 693*sin(d*x + c)^9/(cos(d*x + c) + 1)^9 + 2)/((a^4 + 8*a^4*sin(d*x + c)/(cos(d*x + c) + 1) + 25*a^4*si
n(d*x + c)^2/(cos(d*x + c) + 1)^2 + 32*a^4*sin(d*x + c)^3/(cos(d*x + c) + 1)^3 - 11*a^4*sin(d*x + c)^4/(cos(d*
x + c) + 1)^4 - 88*a^4*sin(d*x + c)^5/(cos(d*x + c) + 1)^5 - 99*a^4*sin(d*x + c)^6/(cos(d*x + c) + 1)^6 + 99*a
^4*sin(d*x + c)^8/(cos(d*x + c) + 1)^8 + 88*a^4*sin(d*x + c)^9/(cos(d*x + c) + 1)^9 + 11*a^4*sin(d*x + c)^10/(
cos(d*x + c) + 1)^10 - 32*a^4*sin(d*x + c)^11/(cos(d*x + c) + 1)^11 - 25*a^4*sin(d*x + c)^12/(cos(d*x + c) + 1
)^12 - 8*a^4*sin(d*x + c)^13/(cos(d*x + c) + 1)^13 - a^4*sin(d*x + c)^14/(cos(d*x + c) + 1)^14)*d)

________________________________________________________________________________________

Fricas [A]  time = 1.71831, size = 409, normalized size = 2.82 \begin{align*} -\frac{488 \, \cos \left (d x + c\right )^{6} - 1220 \, \cos \left (d x + c\right )^{4} + 1120 \, \cos \left (d x + c\right )^{2} +{\left (122 \, \cos \left (d x + c\right )^{6} - 915 \, \cos \left (d x + c\right )^{4} + 1400 \, \cos \left (d x + c\right )^{2} - 735\right )} \sin \left (d x + c\right ) - 420}{3465 \,{\left (a^{4} d \cos \left (d x + c\right )^{7} - 8 \, a^{4} d \cos \left (d x + c\right )^{5} + 8 \, a^{4} d \cos \left (d x + c\right )^{3} - 4 \,{\left (a^{4} d \cos \left (d x + c\right )^{5} - 2 \, a^{4} d \cos \left (d x + c\right )^{3}\right )} \sin \left (d x + c\right )\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^4*sin(d*x+c)^4/(a+a*sin(d*x+c))^4,x, algorithm="fricas")

[Out]

-1/3465*(488*cos(d*x + c)^6 - 1220*cos(d*x + c)^4 + 1120*cos(d*x + c)^2 + (122*cos(d*x + c)^6 - 915*cos(d*x +
c)^4 + 1400*cos(d*x + c)^2 - 735)*sin(d*x + c) - 420)/(a^4*d*cos(d*x + c)^7 - 8*a^4*d*cos(d*x + c)^5 + 8*a^4*d
*cos(d*x + c)^3 - 4*(a^4*d*cos(d*x + c)^5 - 2*a^4*d*cos(d*x + c)^3)*sin(d*x + c))

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)**4*sin(d*x+c)**4/(a+a*sin(d*x+c))**4,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [A]  time = 1.34311, size = 232, normalized size = 1.6 \begin{align*} -\frac{\frac{1155 \,{\left (3 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - 1\right )}}{a^{4}{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - 1\right )}^{3}} - \frac{3465 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{9} + 47355 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{8} + 309540 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{7} + 588588 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{6} + 891198 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{5} + 747450 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{4} + 481140 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{3} + 172700 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} + 35233 \, \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 3203}{a^{4}{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 1\right )}^{11}}}{110880 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^4*sin(d*x+c)^4/(a+a*sin(d*x+c))^4,x, algorithm="giac")

[Out]

-1/110880*(1155*(3*tan(1/2*d*x + 1/2*c) - 1)/(a^4*(tan(1/2*d*x + 1/2*c) - 1)^3) - (3465*tan(1/2*d*x + 1/2*c)^9
 + 47355*tan(1/2*d*x + 1/2*c)^8 + 309540*tan(1/2*d*x + 1/2*c)^7 + 588588*tan(1/2*d*x + 1/2*c)^6 + 891198*tan(1
/2*d*x + 1/2*c)^5 + 747450*tan(1/2*d*x + 1/2*c)^4 + 481140*tan(1/2*d*x + 1/2*c)^3 + 172700*tan(1/2*d*x + 1/2*c
)^2 + 35233*tan(1/2*d*x + 1/2*c) + 3203)/(a^4*(tan(1/2*d*x + 1/2*c) + 1)^11))/d